A magnetic sensor may be capable of sensing components of a magnetic field applied to the magnetic sensor, such as a magnetic field magnitude, magnetic field intensity, a magnetic field direction (e.g., based on directional components of the magnetic field), and/or the like. The magnetic field of the magnet may depend on a magnetization of the magnet, a shape of the magnet, an environment of the magnet, and/or other factors. The magnetic sensor may be used to detect, for example, movement, position, an angle of rotation, and/or the like, of a magnet, which may be connected to an object, in a variety of applications, such as a mechanical application, an industrial application, or a consumer application.